if(Boost_INCLUDE_DIRS)
    set(INCLUDES ${Boost_INCLUDE_DIRS})
    set(LIBS ${Boost_LIBRARIES})
else(Boost_INCLUDE_DIRS)
    set(LIBS Boost::boost)
endif(Boost_INCLUDE_DIRS)
include_directories(
    ${PROJECT_SOURCE_DIR}
    ${INCLUDES}
    )
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
    set(COMPILE_DEFINITIONS DEBUG_TFPARSER)
else()
    set(COMPILE_DEFINITIONS "")
endif()

add_executable(test_tf_spirit test_spirit.cpp)
set_target_properties(test_tf_spirit PROPERTIES OUTPUT_NAME "test_spirit")
if(LIBS)
    target_link_libraries(test_tf_spirit PRIVATE ${LIBS})
endif(LIBS)
if(COMPILE_DEFINITIONS)
    target_compile_definitions(test_tf_spirit PRIVATE ${COMPILE_DEFINITIONS})
endif(COMPILE_DEFINITIONS)
if(INSTALL_LIMBO)
    install(TARGETS test_tf_spirit DESTINATION test/parsers/tf)
    install(DIRECTORY benchmarks DESTINATION test/parsers/tf)
endif(INSTALL_LIMBO)
